package pkg

//func Upload(file *multipart.FileHeader) (string, error) {
//	Yun := appconfig.Config.QiNiuYun
//	accessKey := Yun.AccessKey
//	secretKey := Yun.SecretKey
//	mac := credentials.NewCredentials(accessKey, secretKey)
//	bucket := Yun.Bucket
//	key := file.Filename
//	uploadManager := uploader.NewUploadManager(&uploader.UploadManagerOptions{
//		Options: http_client.Options{
//			Credentials: mac,
//		},
//	})
//	err := uploadManager.UploadReader(context.Background(), file, &uploader.ObjectOptions{
//		BucketName: bucket,
//		ObjectName: &key,
//		CustomVars: map[string]string{
//			"name": "github logo",
//		},
//		FileName: key,
//	}, nil)
//	return Yun.Url + key, err
//}
